<!--
  ~ Copyright (c) 2023 QMJY.
  ~
  ~  Licensed under the Apache License, Version 2.0 (the "License");
  ~  you may not use this file except in compliance with the License.
  ~  You may obtain a copy of the License at
  ~
  ~        https://www.apache.org/licenses/LICENSE-2.0
  ~
  ~   Unless required by applicable law or agreed to in writing, software
  ~   distributed under the License is distributed on an "AS IS" BASIS,
  ~   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~   See the License for the specific language governing permissions and
  ~   limitations under the License.
  -->

<!DOCTYPE html>
<html lang="zh-Hans-CN" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>样式文件列表</title>
    <link rel="stylesheet" type="text/css" th:href="@{/static/css/style.css}">
</head>
<body>
<h1>样式文件列表</h1>
<hr>

<table th:if="${styles}" cellspacing="10">
    <tr>
        <th>名称</th>
    </tr>
    <tr th:each="style:${styles}">
        <td><a th:href="@{'/api/styles/'+${style.name}}" th:text="${style.name}"></a></td>
    </tr>
</table>

<!--/* tileFiles为空时显示 */-->
<div th:unless="${styles}">未检测到样式文件目录</div>

<hr>
<div class="notice">未检测到样式文件目录，则请检查服务器启动参数：“--dataPath=xxx”,且文件结构如下:
<pre>
    data
    │
    ├─fonts
    │  └─Arial Regular
    │         0-255.pbf
    │         15616-15871.pbf
    │         15872-16127.pbf
    │
    ├─sprites
    │  └─streets
    │          sprite.json
    │          sprite.png
    │          sprite@2x.json
    │          sprite@2x.png
    │
    ├─styles
    │      world.json
    │
    └─tilesets
            Beijing.mbtiles
            Hongkong.mbtiles
</pre>
</div>
</body>
</html>
